/*     */ package eos.moe.dragoncore;
/*     */ 
/*     */ import java.util.HashMap;
/*     */ import java.util.LinkedHashMap;
/*     */ import java.util.List;
/*     */ import java.util.Locale;
/*     */ import java.util.Map;
/*     */ import java.util.concurrent.ConcurrentHashMap;
/*     */ import java.util.concurrent.CopyOnWriteArrayList;
/*     */ import java.util.concurrent.Future;
/*     */ import java.util.function.Function;
/*     */ import java.util.regex.Matcher;
/*     */ import java.util.regex.Pattern;
/*     */ import net.minecraft.client.renderer.GlStateManager;
/*     */ import net.minecraft.entity.EntityLivingBase;
/*     */ import org.yaml.snakeyamla.configuration.ConfigurationSection;
/*     */ import org.yaml.snakeyamla.configuration.file.YamlConfiguration;
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ public class wo
/*     */ {
/*     */   private final qp j;
/*     */   public boolean c;
/*     */   public boolean r;
/*     */   public String f;
/*     */   public List<Future> s;
/*     */   private Map<String, rq> m;
/*     */   public Map<String, rq> l;
/*     */   public Map<String, bh> t;
/*     */   public Map<String, String> d;
/*     */   public bh z;
/*     */   private YamlConfiguration i;
/*     */   public EntityLivingBase w;
/*     */   
/*     */   public wo(EntityLivingBase entityLivingBase, YamlConfiguration yamlConfiguration) {
/*  52 */     this.i = yamlConfiguration;
/*  53 */     this.w = entityLivingBase;
/*  54 */     this.f = yamlConfiguration.getString("display", "aim").toLowerCase(Locale.ROOT);
/*  55 */     this.r = yamlConfiguration.getBoolean("throuth");
/*  56 */     this.s = new CopyOnWriteArrayList<>();
/*  57 */     this.t = new HashMap<>();
/*  58 */     this.d = new HashMap<>();
/*  59 */     this.m = new LinkedHashMap<>();
/*  60 */     this.j = uu.v(this);
/*  61 */     this.j.v("方法", "func", v());
/*     */     
/*  63 */     this.z = v(yamlConfiguration.get("offsetY", "方法.取实体高度+0.25"));
/*     */     
/*  65 */     for (String str : this.i.getKeys(false)) {
/*  66 */       ConfigurationSection configurationSection1 = yamlConfiguration.getConfigurationSection(str);
/*     */       
/*  68 */       rq rq = v(configurationSection1);
/*  69 */       if (rq != null) {
/*  70 */         this.m.put(configurationSection1.getName(), rq);
/*     */       }
/*     */     } 
/*     */     
/*  74 */     ConfigurationSection configurationSection = this.i.getConfigurationSection("Functions");
/*  75 */     if (configurationSection != null) {
/*  76 */       for (String str : configurationSection.getKeys(false)) {
/*  77 */         this.t.put(str.toLowerCase(Locale.ROOT), v(configurationSection.get(str)));
/*     */       }
/*     */     }
/*     */     
/*  81 */     v();
/*     */   }
/*     */   
/*     */   public void v() {
/*  85 */     if (this.l != null) {
/*  86 */       this.l.clear();
/*     */     }
/*  88 */     this.l = new ConcurrentHashMap<>();
/*  89 */     for (Map.Entry<String, rq> entry : this.m.entrySet()) {
/*  90 */       this.l.put(((String)entry.getKey()).toLowerCase(Locale.ROOT), (rq)entry.getValue());
/*     */     }
/*     */   }
/*     */ 
/*     */   
/*     */   public rq v(ConfigurationSection configurationSection) {
/*  96 */     if (configurationSection == null || !configurationSection.contains("type")) {
/*  97 */       return null;
/*     */     }
/*  99 */     String str = configurationSection.getString("type");
/* 100 */     if (str == null)
/* 101 */       return null; 
/* 102 */     switch (str.toLowerCase(Locale.ROOT)) {
/*     */       case "l":
/*     */       case "label":
/*     */       case "文本":
/* 106 */         return new is(this, configurationSection);
/*     */       case "t":
/*     */       case "texture":
/*     */       case "图片":
/* 110 */         return new gx(this, configurationSection);
/*     */     } 
/* 112 */     return null;
/*     */   }
/*     */   
/*     */   public eu v() {
/* 116 */     eu eu = new eu(new HashMap<>());
/* 117 */     eu.v().putAll(gw.g.v());
/* 118 */     ep.v(ip.class, this, eu);
/* 119 */     ep.v(gm.class, this, eu);
/* 120 */     ep.v(dr.class, this, eu);
/* 121 */     ep.v(nl.class, this, eu);
/* 122 */     ep.v(eg.class, this, eu);
/* 123 */     ep.v(yk.class, this, eu);
/* 124 */     ep.v(kl.class, this, eu);
/* 125 */     ep.v(de.class, this, eu);
/* 126 */     ep.v(wf.class, this, eu);
/* 127 */     ep.v(bl.class, this, eu);
/* 128 */     ep.v(je.class, this, eu);
/* 129 */     ep.v(zn.class, this, eu);
/* 130 */     ep.v(wk.class, this, eu);
/* 131 */     ep.v(yl.class, this, eu);
/* 132 */     ep.v(do.class, this, eu);
/* 133 */     ep.v(ew.class, this, eu);
/* 134 */     ep.v(km.class, this, eu);
/* 135 */     ep.v(qy.class, this, eu);
/* 136 */     ep.v(oo.class, this, eu);
/*     */     
/* 138 */     return eu;
/*     */   }
/*     */ 
/*     */   
/*     */   public void v(EntityLivingBase entityLivingBase, float f, boolean bool) {
/* 143 */     for (rq rq : this.m.values()) {
/* 144 */       rq.z(entityLivingBase, f, bool);
/* 145 */       GlStateManager.func_179137_b(0.0D, 0.0D, -0.01D);
/*     */     } 
/*     */   }
/*     */   
/*     */   public boolean v(wn wn1) {
/* 150 */     return z(wn1.v());
/*     */   }
/*     */   
/*     */   public boolean z(String str) {
/* 154 */     bh bh1 = this.t.get(str);
/* 155 */     if (bh1 != null) {
/* 156 */       return bh1.z();
/*     */     }
/* 158 */     return false;
/*     */   }
/*     */ 
/*     */   
/*     */   public Map<String, rq> v() {
/* 163 */     return this.m;
/*     */   }
/*     */   
/*     */   public bh v(Object object) {
/* 167 */     String str = String.valueOf(object);
/* 168 */     if (str.startsWith("co|") || str.startsWith("mo|")) {
/* 169 */       str = str.substring(3);
/*     */     }
/*     */     
/* 172 */     str = v(str);
/* 173 */     return uu.v(this.j, str);
/*     */   }
/*     */ 
/*     */   
/*     */   public bh v(String str) {
/* 178 */     if (!str.startsWith("co|") && !str.startsWith("mo|")) {
/*     */ 
/*     */       
/* 181 */       if (v(str)) {
/* 182 */         str = v(str);
/* 183 */         return uu.v(this.j, str);
/*     */       } 
/*     */       
/* 186 */       if (!str.startsWith("'")) {
/* 187 */         str = "'" + str + "'";
/*     */       }
/*     */     } else {
/* 190 */       str = str.substring(3);
/*     */     } 
/* 192 */     str = v(str);
/*     */     
/* 194 */     return uu.v(this.j, str);
/*     */   }
/*     */   
/* 197 */   private static final Pattern q = Pattern.compile("[']([^']+)[']");
/* 198 */   private static final Pattern g = Pattern.compile("[%]([^%]+)[%]");
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */ 
/*     */   
/*     */   public YamlConfiguration v() {
/* 229 */     return this.i;
/*     */   }
/*     */ }


/* Location:              D:\fanbian\[D][龙之核心]DragonCore-2.6.0.3.jar!\eos\moe\dragoncore\wo.class
 * Java compiler version: 8 (52.0)
 * JD-Core Version:       1.1.3
 */